﻿<common:LayoutAwarePage
    x:Name="pageRoot"
    x:Class="DrawingTemplate.HubPage"
    DataContext="{Binding DefaultViewModel, RelativeSource={RelativeSource Self}}"
    IsTabStop="false"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:DrawingTemplate"
    xmlns:common="using:DrawingTemplate.Common"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d">

    <Page.Resources>

        <!-- TODO: Delete this line if the key AppName is declared in App.xaml -->
        <x:String x:Key="AppName">My Application</x:String>
        <Style x:Key="ButtonStyle1" TargetType="Button">
            <Setter Property="Background" Value="{StaticResource ButtonBackgroundThemeBrush}"/>
            <Setter Property="Foreground" Value="{StaticResource ButtonForegroundThemeBrush}"/>
            <Setter Property="BorderBrush" Value="{StaticResource ButtonBorderThemeBrush}"/>
            <Setter Property="BorderThickness" Value="{StaticResource ButtonBorderThemeThickness}"/>
            <Setter Property="Padding" Value="12,4,12,4"/>
            <Setter Property="HorizontalAlignment" Value="Left"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
            <Setter Property="FontFamily" Value="{StaticResource ContentControlThemeFontFamily}"/>
            <Setter Property="FontWeight" Value="SemiBold"/>
            <Setter Property="FontSize" Value="{StaticResource ControlContentThemeFontSize}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid>
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="PointerOver">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="Border">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonPointerOverBackgroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentPresenter">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonPointerOverForegroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <DoubleAnimation Duration="0" To="0.995" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="image" d:IsOptimized="True"/>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="image">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Visible</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="Border">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonPressedBackgroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentPresenter">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonPressedForegroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="Border">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonDisabledBackgroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="Border">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonDisabledBorderThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentPresenter">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonDisabledForegroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused">
                                        <Storyboard>
                                            <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="FocusVisualWhite"/>
                                            <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="FocusVisualBlack"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Unfocused"/>
                                    <VisualState x:Name="PointerFocused"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Border x:Name="Border" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Margin="3">
                                <ContentPresenter x:Name="ContentPresenter" ContentTemplate="{TemplateBinding ContentTemplate}" ContentTransitions="{TemplateBinding ContentTransitions}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Content=""/>
                            </Border>
                            <Rectangle x:Name="FocusVisualWhite" IsHitTestVisible="False" Opacity="0" StrokeDashOffset="1.5" StrokeEndLineCap="Square" Stroke="{StaticResource FocusVisualWhiteStrokeThemeBrush}" StrokeDashArray="1,1"/>
                            <Rectangle x:Name="FocusVisualBlack" IsHitTestVisible="False" Opacity="0" StrokeDashOffset="0.5" StrokeEndLineCap="Square" Stroke="{StaticResource FocusVisualBlackStrokeThemeBrush}" StrokeDashArray="1,1"/>
                            <Image x:Name="image" HorizontalAlignment="Left" Height="60" VerticalAlignment="Top" Width="60" Source="images/save.png"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="ButtonStyle2" TargetType="Button">
            <Setter Property="Background" Value="{StaticResource ButtonBackgroundThemeBrush}"/>
            <Setter Property="Foreground" Value="{StaticResource ButtonForegroundThemeBrush}"/>
            <Setter Property="BorderBrush" Value="{StaticResource ButtonBorderThemeBrush}"/>
            <Setter Property="BorderThickness" Value="{StaticResource ButtonBorderThemeThickness}"/>
            <Setter Property="Padding" Value="12,4,12,4"/>
            <Setter Property="HorizontalAlignment" Value="Left"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
            <Setter Property="FontFamily" Value="{StaticResource ContentControlThemeFontFamily}"/>
            <Setter Property="FontWeight" Value="SemiBold"/>
            <Setter Property="FontSize" Value="{StaticResource ControlContentThemeFontSize}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid>
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="PointerOver">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="Border">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonPointerOverBackgroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentPresenter">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonPointerOverForegroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <DoubleAnimation Duration="0" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="image" d:IsOptimized="True" To="0.995"/>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Visibility)" Storyboard.TargetName="image">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Visible</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="Border">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonPressedBackgroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentPresenter">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonPressedForegroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="Border">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonDisabledBackgroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="Border">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonDisabledBorderThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentPresenter">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonDisabledForegroundThemeBrush}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused">
                                        <Storyboard>
                                            <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="FocusVisualWhite"/>
                                            <DoubleAnimation Duration="0" To="1" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="FocusVisualBlack"/>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Unfocused"/>
                                    <VisualState x:Name="PointerFocused"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Border x:Name="Border" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Margin="3">
                                <ContentPresenter x:Name="ContentPresenter" ContentTemplate="{TemplateBinding ContentTemplate}" ContentTransitions="{TemplateBinding ContentTransitions}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Content=""/>
                            </Border>
                            <Rectangle x:Name="FocusVisualWhite" IsHitTestVisible="False" Opacity="0" StrokeDashOffset="1.5" StrokeEndLineCap="Square" Stroke="{StaticResource FocusVisualWhiteStrokeThemeBrush}" StrokeDashArray="1,1"/>
                            <Rectangle x:Name="FocusVisualBlack" IsHitTestVisible="False" Opacity="0" StrokeDashOffset="0.5" StrokeEndLineCap="Square" Stroke="{StaticResource FocusVisualBlackStrokeThemeBrush}" StrokeDashArray="1,1"/>
                            <Image x:Name="image" HorizontalAlignment="Left" Height="60" VerticalAlignment="Top" Width="60" Source="images/appundo.png"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
    </Page.Resources>

    <!--
        This grid acts as a root panel for the page that defines two rows:
        * Row 0 contains the back button and page title
        * Row 1 contains the rest of the page layout
    -->
    <Grid>
        <Grid.Background>
            <ImageBrush ImageSource="images/bg2.png" Stretch="Fill"/>
        </Grid.Background>
        <Grid.RowDefinitions>
            <RowDefinition Height="140"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>

        <!-- Back button and page title -->
        <Grid>
            <!--<Button x:Name="backButton" Click="GoBack" IsEnabled="{Binding Frame.CanGoBack, ElementName=pageRoot}" Style="{StaticResource BackButtonStyle}"/>-->
            <TextBlock Margin="120,0,0,50" x:Name="pageTitle" Text="Your App Slogan / Logo Goes Here" Foreground="Black" Style="{StaticResource PageHeaderTextStyle}" Grid.Column="1"/>
        </Grid>

        <ScrollViewer x:Name="MainScroll" Margin="0" Grid.Row="1" HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Disabled">
            <StackPanel HorizontalAlignment="Left" Margin="120,0,0,0" VerticalAlignment="Top" Width="1222" Orientation="Horizontal" >
                <Grid Margin="0,58,0,0" HorizontalAlignment="Left" VerticalAlignment="Top">
                    <GridViewItem x:Name="left1" HorizontalAlignment="Left" Margin="0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo1.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy" HorizontalAlignment="Left" Margin="102,0,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo4.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy1" HorizontalAlignment="Left" Margin="204,0,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo2.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy2" HorizontalAlignment="Left" Margin="0,84,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo3.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy3" HorizontalAlignment="Left" Margin="102,84,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo6.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy4" HorizontalAlignment="Left" Margin="204,84,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo1.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy5" HorizontalAlignment="Left" Margin="0,170,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo2.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy6" HorizontalAlignment="Left" Margin="102,170,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo4.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy7" HorizontalAlignment="Left" Margin="204,170,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo3.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy8" HorizontalAlignment="Left" Margin="0,262,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo1.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy9" HorizontalAlignment="Left" Margin="102,262,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo4.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="left1_Copy10" HorizontalAlignment="Left" Margin="204,262,0,0" VerticalAlignment="Top" Tapped="left1_Tapped" >
                        <Image Height="80" Source="images/PicColo5.png" Stretch="Fill" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center"/>
                    </GridViewItem>
                </Grid>
                <Image Margin="25,0,0,0" Source="images/bordbg.png" Stretch="Fill" Width="550" Height="621" HorizontalAlignment="Center" VerticalAlignment="Top"/>
                <Grid Margin="25,63,0,0" VerticalAlignment="Top">
                    <GridViewItem x:Name="right1" HorizontalAlignment="Left" Margin="0" VerticalAlignment="Top" Tapped="right1_Tapped">
                        <Image Source="images/paintIcon.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,1,0,0"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right2" HorizontalAlignment="Left" Margin="100,0,0,0" VerticalAlignment="Top" Tapped="right2_Tapped" >
                        <Image Source="images/erasericoner.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0,1,0,0"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right3" HorizontalAlignment="Left" Margin="0,91,0,0" VerticalAlignment="Top" Tapped="right3_Tapped">
                        <Image Source="images/pickerIcon.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right4" HorizontalAlignment="Left" Margin="100,91,0,0" VerticalAlignment="Top" Tapped="right4_Tapped">
                        <Image Source="images/zoomIcon.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right5" HorizontalAlignment="Left" Margin="0,177,160,0" VerticalAlignment="Top" Tapped="right5_Tapped">
                        <Image Source="images/panice.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right6" HorizontalAlignment="Left" Margin="100,177,0,0" VerticalAlignment="Top" Tapped="right6_Tapped">
                        <Image Source="images/covr.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right5_Copy" HorizontalAlignment="Left" Margin="200,0,0,0" VerticalAlignment="Top" Tapped="right5_Tapped">
                        <Image Source="images/paintIcon.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,1,0,0"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right6_Copy" HorizontalAlignment="Left" Margin="200,92,0,0" VerticalAlignment="Top" Tapped="right6_Tapped">
                        <Image Source="images/pickerIcon.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right5_Copy1" HorizontalAlignment="Left" Margin="200,177,0,0" VerticalAlignment="Top" Tapped="right5_Tapped">
                        <Image Source="images/erasericoner.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right5_Copy2" HorizontalAlignment="Left" Margin="0,266,0,0" VerticalAlignment="Top" Tapped="right5_Tapped">
                        <Image Source="images/handIcon.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right6_Copy1" HorizontalAlignment="Left" Margin="100,266,0,0" VerticalAlignment="Top" Tapped="right6_Tapped">
                        <Image Source="images/textadit.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                    <GridViewItem x:Name="right5_Copy3" HorizontalAlignment="Left" Margin="200,266,0,0" VerticalAlignment="Top" Tapped="right5_Tapped">
                        <Image Source="images/zoomIcon.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </GridViewItem>
                </Grid>
            </StackPanel>
        </ScrollViewer>

        <Grid x:Name="gridSnap" Visibility="Collapsed" Grid.Row="1" Margin="10,0">
            <TextBlock Foreground="#000000" TextWrapping="Wrap" FontSize="26" HorizontalAlignment="Center" VerticalAlignment="Center" 
                       Text="Please switch to full screen to view the details." TextAlignment="Center"/>
        </Grid>

        <VisualStateManager.VisualStateGroups>

            <!-- Visual states reflect the application's view state -->
            <VisualStateGroup>
                <VisualState x:Name="FullScreenLandscape"/>
                <VisualState x:Name="Filled"/>

                <!-- The entire page respects the narrower 100-pixel margin convention for portrait -->
                <VisualState x:Name="FullScreenPortrait">
                </VisualState>

                <!-- The back button and title have different styles when snapped -->
                <VisualState x:Name="Snapped">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="pageTitle" Storyboard.TargetProperty="Style">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource SnappedPageHeaderTextStyle}"/>
                        </ObjectAnimationUsingKeyFrames>

                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="pageTitle" Storyboard.TargetProperty="Margin">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="40,0,0,50"/>
                        </ObjectAnimationUsingKeyFrames>

                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="gridSnap" Storyboard.TargetProperty="Visibility">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                        </ObjectAnimationUsingKeyFrames>

                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="MainScroll" Storyboard.TargetProperty="Visibility">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
            </VisualStateGroup>
        </VisualStateManager.VisualStateGroups>
    </Grid>
    <common:LayoutAwarePage.BottomAppBar>
        <AppBar Height="88" Background="#F2333333">
            <Grid Margin="0">
                <StackPanel Orientation="Horizontal" HorizontalAlignment="Left">
                    <Button Style="{StaticResource SaveAppBarButtonStyle}" Margin="80,0,0,0"/>
                    <Button Style="{StaticResource RefreshAppBarButtonStyle}" />
                </StackPanel>
            </Grid>
        </AppBar>
    </common:LayoutAwarePage.BottomAppBar>
</common:LayoutAwarePage>
